home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Controls / Visual Basic Controls.iso / vbcontrol / cstwnd / extras.h < prev    next >
Encoding:
C/C++ Source or Header  |  1993-12-29  |  1.3 KB  |  50 lines

  1. #ifndef _CEXTRAS_H_
  2. #define _CEXTRAS_H_
  3.  
  4. #ifndef _CUSTWIND_H_
  5. #include <bar.h>
  6. #endif
  7.  
  8. #ifndef _BITOVER_H_
  9. #include <bitover.h>
  10. #endif
  11.  
  12. #ifndef __EDIT_H
  13. #include <edit.h>
  14. #endif
  15.  
  16. /*******************************************************************
  17. A Message box with the supplied text and title.  Uses a
  18. custom dialog box with an appropriate background.  Sounds
  19. the cooresponding message beep.
  20. *******************************************************************/
  21. int _EXPORT CMessageBox(PTWindowsObject Parent, LPCSTR Text,
  22.     LPCSTR Title, UINT Style, PTModule Module);
  23.  
  24. _CLASSDEF(TCMessageDlg)
  25. class _EXPORT TCMessageDlg : public TBarDialog,
  26.     public TBitOver
  27. {
  28.    PTEdit TheMessage;
  29.     UINT    Style;
  30.     int Ids[3];
  31.     char HasCancel;
  32.     char* Text;
  33.     char* Title;
  34.     void End(int Button);
  35. public:
  36.     TCMessageDlg(PTWindowsObject AParent,
  37.         LPSTR AName, LPCSTR AText,
  38.         LPCSTR ATitle, UINT AStyle, PTModule AModule,
  39.         PCustColors Colors, PCustCursors Cursors);
  40.     ~TCMessageDlg();
  41.  
  42.     virtual void SetupWindow();
  43.  
  44.     virtual void Button1(RTMessage) = [ID_FIRST + ID_BUTTON1];
  45.     virtual void Button2(RTMessage) = [ID_FIRST + ID_BUTTON2];
  46.    virtual void Button3(RTMessage) = [ID_FIRST + ID_BUTTON3];
  47.     virtual void WMSysCommand(RTMessage Msg) = [WM_FIRST + WM_SYSCOMMAND];
  48. };
  49.  
  50. #endif